function getYuan(cent) {
  if (undefined === cent) {
    return Number(0)
  }
  return (cent / 100).toFixed(2)
}

function getCent(yuan) {
  if (undefined === yuan) {
    return Number(0)
  }
  return (yuan * 100).toFixed(0)
}

module.exports = {
  getYuan,
  getCent
}
